The present aspects relate to a computer device, and more particularly, to discovery of services available from devices with which the computer device may communicate.
When a computer device discovers a device with which it can communicate over any one of a plurality of protocols (e.g., Bluetooth, Universal Plug and Play (UPnP), Wireless Fidelity (Wi-Fi) Direct, etc.), it is difficult for the computer device to ascertain what the device can do by simply discovering the device. For example, an application on the computer device may discover a connected device or a device with which the computer device may initiate communication, also referred to as an “endpoint,” such as an endpoint that represents a television on a network, and through one or more queries may determine that the television supports streaming video. For the application to determine whether the television supports a specific type of streaming video, such as UPnP and Digital Living Network Alliance (DLNA), however, the application may need to query the television directly, e.g., using a protocol-specific language and/or procedure, to identify the services supported by the television. In this scenario, for every device service an application wants to incorporate into an application, the application needs to understand one or more protocols associated with devices that can provide the service, and implement different programming models for each protocol. For example, if an application on a computer device such as a phone wants to stream audio to a car stereo using a BLUETOOTH connection, both the car stereo and the phone need to support an Advanced Audio Distribution Profile (A2DP) profile, which defines how audio can be streamed from one device to another over a BLUETOOTH connection. In this case, the application may use a Socket Direct Protocol (SDP) Application Programming Interface (API) of an Operating System (OS) on the phone to figure out if a device has services the application knows how to use. As such, for each service an application wants to incorporate, the application must query a device and try to figure out if the device has services the application knows how to use.
Thus, there is a need in the art for improved interoperation between applications and devices.